<?php include_partial('common/flashes') ?>
<form id="patient-question-form" action="<?php echo url_for('@patient_question_create') ?>" method="post">
    <div id="patient-question-block">
        <?php echo $form->renderHiddenFields(false) ?>
        <div id="left-question-block">
            <?php include_partial("common/input_field", array("form" => $form, "field" => "enquiry", "show_label" => false)) ?>              
        </div>
        <div id="right-question-block">
            <button id="submit-patient-question" class="button-thickest-blue" type="submit">Ask</button>             
        </div>     
    </div>
</form>
<script type="text/javascript">
    //<![CDATA[
    $(document).ready(function(){
        // make an attempt to submit this form
        $('#submit-patient-question').click(function() {
            $('#patient-question-form').ajaxSubmit(function(data){                 
                $("#patient-question-form-holder").html(data);
            });
            return false;
        });
    });
    //]]>
</script>